<template>
  <div style="min-height: 100vh">
    <el-container style="height:100vh;">
      <el-aside :width="sideWidth+'px'" style="background-color: rgb(238, 241, 246);">
        <Aside :isCollapse="isCollapse" :logoTextShow="logoTextShow"/>
      </el-aside>

      <el-container>
        <el-header style="border-bottom: 1px solid #ccc">
          <Header :collapseBtnClass="collapseBtnClass" :collapse="isCollapse" />
        </el-header>
        <!-- Form -->
        <el-main>
<!--          表示当前页面的子路由会在 router-view 里面展示-->
          <router-view/>
        </el-main>
      </el-container>
    </el-container>

  </div>
</template>

<script>
import Aside from "@/components/seller/Aside.vue";
import Header from "@/components/seller/Header.vue";

export default {
  name: 'Manager',
  components: {Header, Aside},
  data(){
    return{

      msg:"hello world",
      collapseBtnClass: 'el-icon-s-fold',
      isCollapse:false,
      sideWidth:200,
      logoTextShow:true,

    }
  },
  // created() {
  //   //请求分页查询数据
  //   this.load()
  //   },

  methods:{
    collapse(){//点击收缩按钮触发
      this.isCollapse=!this.isCollapse
        if(this.isCollapse){//收缩
          this.sideWidth=64
          this.collapseBtnClass='el-icon-s-unfold'
          this.logoTextShow=false
        }else {//展开
          this.sideWidth=200
          this.collapseBtnClass='el-icon-s-fold'
          this.logoTextShow=true
        }
    },
    // components(){
    //   Aside,
    //   Header
    // },

  }
}
</script>


